/*
 * Copyright 2003-2005 (c) Live Media Pty Ltd. <argot@einet.com.au> 
 *
 * This software is licensed under the Argot Public License 
 * which may be found in the file LICENSE distributed 
 * with this software.
 *
 * More information about this license can be found at
 * http://www.einet.com.au/License
 * 
 * The Developer of this software is Live Media Pty Ltd,
 * PO Box 4591, Melbourne 3001, Australia.  The license is subject 
 * to the law of Victoria, Australia, and subject to exclusive 
 * jurisdiction of the Victorian courts.
 */

#ifndef TYPELIBRARYTEST_H_
#define TYPELIBRARYTEST_H_

#include <cppunit/extensions/HelperMacros.h>

class TypeLibraryTest : public CPPUNIT_NS::TestFixture
{
  CPPUNIT_TEST_SUITE( TypeLibraryTest );
  CPPUNIT_TEST( testCreateTypeLibrary );
  CPPUNIT_TEST( testReserveType );
  CPPUNIT_TEST( testNotDefinedTypeState );
  CPPUNIT_TEST( testRegisterStructure );
  CPPUNIT_TEST( testRegisterComplete );
  CPPUNIT_TEST( testRegisterAfterReserve );
  CPPUNIT_TEST( testBind );
  CPPUNIT_TEST( testBindException );
  CPPUNIT_TEST( testGetStructure );
  CPPUNIT_TEST( testGetReader );
  CPPUNIT_TEST( testGetReaderFail );
  CPPUNIT_TEST( testGetWriter );
  CPPUNIT_TEST( testGetWriterFail );
  CPPUNIT_TEST( testRegisterAfterReserveCheckId );
  CPPUNIT_TEST( testNullNameForGetId );
  CPPUNIT_TEST_SUITE_END();

protected:
  type_library _library;

public:
  virtual void setUp();

protected:
  void testCreateTypeLibrary();
  void testReserveType();
  void testNotDefinedTypeState();
  void testRegisterStructure();
  void testRegisterComplete();
  void testRegisterAfterReserve();
  void testBind();
  void testBindException();
  void testGetStructure();
  void testGetReader();
  void testGetReaderFail();
  void testGetWriter();
  void testGetWriterFail();
  void testGetClassId();
  void testGetClassIdAfterReserve();
  void testRegisterAfterReserveCheckId();
  void testMixedCaseNames();
  void testNullNameForGetId();
};

#endif
